 <!DOCTYPE html>
<html lang="en" xmlns:th="http://www.w3.org/1999/xhtml">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width,initial-scale=1.0">
    <title>注册</title>
    <link type="text/css" rel="stylesheet" href="../static/css/bootstrap.min.css" th:href="@{/css/bootstrap.min.css}">
    <link type="text/css" rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css" th:href="@{https://unpkg.com/element-ui/lib/theme-chalk/index.css}">
    <link type="text/css" rel="stylesheet" href="../static/css/login-to-register-module.css" th:href="@{/css/login-to-register-module.css}">
</head>
<body>
<div class="container">
    <div class="row">
        <div class="col-md-offset-3 col-md-6">
            <form class="form-horizontal" method="post" th:action="@{/saveuser}" th:object="${user}">
                <div class="form-group">
                    <a th:href="@{/index}" id="logo"><h2>流沙</h2></a>
                </div>
                <hr>
                <div class="form-group">
                    <a th:href="@{/login}" type="button" class="heading login">登录</a>
                    <a th:href="@{/registered}" type="button" class="heading register">注册</a>
                </div>
                <hr>
                <div class="form-group">
                    <i class="el-icon-user-solid"></i>
                    <input type="text" name="nickname" class="form-control" th:field="*{nickname}" required placeholder="你的昵称">
                </div>
                <div class="form-group">
                    <i class="el-icon-user-solid"></i>
                    <input type="text" name="username" class="form-control" th:field="*{username}" required placeholder="用户名">
                </div>
                <div class="form-group help">
                    <i class="el-icon-lock"></i>
                    <input type="password" name="password" class="form-control" th:field="*{password}" required placeholder="设置密码">
                </div>
                <div class="form-group">
                    <i class="el-icon-mobile-phone"></i>
                    <input type="text" name="tel" class="form-control" th:field="*{tel}" required placeholder="手机号">
                </div>
                <div class="form-group">
                    <i class="el-icon-discover"></i>
                    <input type="email" name="email" class="form-control" th:field="*{email}" required placeholder="电子邮件">
                    <input type="hidden" th:field="*{validstate}">
                </div>

                <div class="form-group">
                    <button type="submit" class="btn btn-success">注册</button>
                </div>
            </form>
        </div>
    </div>
</div>


<script type="text/javascript" src="../static/js/jquery.min.js" th:src="@{/js/jquery.min.js}"></script>
<script type="text/javascript" src="../static/js/bootstrap.min.js" th:src="@{/js/bootstrap.min.js}"></script>
<script type="text/javascript" src="https://unpkg.com/element-ui/lib/index.js" th:src="@{https://unpkg.com/element-ui/lib/index.js}"></script>
</body>
</html>
